package com.demo.design.creational.simplefactory;

public class SimpleFactoryDemo {

    public static void main(String[] args) {
        FriutsFactory friutsFactory = new FriutsFactory();

        Product fruit = friutsFactory.getFruits("apple");
        System.err.println(fruit.getProductName());
        System.err.println(fruit.price());

        Product fruit1 = friutsFactory.getFruits("banana");
        System.err.println(fruit1.getProductName());
        System.err.println(fruit1.price());
    }
}
